//-----------------------------------------------------------------------------
//----- WindoMainSht.cpp : implementation file
#include "StdAfx.h"
#include "StdArx.h"
#include "resource.h"
#include "WindoMainSht.h"

//-----------------------------------------------------------------------------
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

//-----------------------------------------------------------------------------
IMPLEMENT_DYNAMIC (CWindoMainSht, CAcUiTabMainDialog)

BEGIN_MESSAGE_MAP(CWindoMainSht, CAcUiTabMainDialog)
	//{{AFX_MSG_MAP(CWindoMainSht)
	ON_MESSAGE(WM_ACAD_KEEPFOCUS, OnAcadKeepFocus)    // Needed for modeless dialog.
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

//-----------------------------------------------------------------------------
CWindoMainSht::CWindoMainSht (CWnd* pParent /*=NULL*/, HINSTANCE hInstance /*=NULL*/) : CAcUiTabMainDialog (CWindoMainSht::IDD, pParent, hInstance) {
	//{{AFX_DATA_INIT(CWindoMainSht)
	//}}AFX_DATA_INIT
}

void CWindoMainSht::DoDataExchange (CDataExchange *pDX) {
	CAcUiTabMainDialog::DoDataExchange (pDX) ;
	//{{AFX_DATA_MAP(CWindoMainSht)
	DDX_Control(pDX, IDC_TAB1, m_tabCtrl);
	//}}AFX_DATA_MAP
}

// Needed for modeless dialogs to keep focus.
// Return FALSE to not keep the focus, return TRUE to keep the focus
LONG CWindoMainSht::OnAcadKeepFocus(UINT, UINT)
{
  return TRUE;
}

//-----------------------------------------------------------------------------

BOOL CWindoMainSht::OnInitDialog() 
{
	CAcUiTabMainDialog::OnInitDialog();
	
	// TODO: Add extra initialization here


	SetAcadTabPointer(&m_tabCtrl);

	m_tabCtrl.AddTab(0, _T("Type"), CWindTypePg::IDD, &m_windPg);
	m_tabCtrl.AddTab(1, _T("Specs"), CWindSpecsPg::IDD, &m_specPg);
	m_tabCtrl.AddTab(2, _T("Start Point"), CWindStartPtPg::IDD, &m_startPtPg);

	
	return TRUE;  // return TRUE unless you set the focus to a control
	              // EXCEPTION: OCX Property Pages should return FALSE
}
